<template>
  <div class="app-container">

    <!--列表数据  -->
    <el-table :data="list" border fit highlight-current-row style="width: 100%;">
      <el-table-column label="真实姓名" prop="realName" align="center"/>
      <el-table-column label="支付金额" prop="totalFee" align="center"/>
      <el-table-column label="支付状态" prop=" isEngineer" align="center">
        <template slot-scope="scope">
          <span v-if="scope.row.payStatus==0">未支付</span>
          <span v-if="scope.row.payStatus==1">已支付</span>
        </template>
      </el-table-column>

      <el-table-column label="交易类型" prop="isEngineer" align="center">
        <template slot-scope="scope">
          <span v-if="scope.row.payType==0">正常酬金</span>
          <span v-if="scope.row. payType==1">小费</span>
        </template>
      </el-table-column>

      <el-table-column label="下单时间" prop="createTime" align="center"/>
      <el-table-column label="支付时间" prop="payTime" align="center"/>


      <!--      <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="435px">-->
      <!--        <template slot-scope="{row}">-->
      <!--          <el-button type="primary" size="mini" @click="handleUpdate(row)" v-show="hasPermission('sys:admin:show')">查看-->
      <!--          </el-button>-->
      <!--          <el-button type="primary" size="mini" @click="lookCode(row)" v-show="hasPermission('sys:google:getusercode')"-->
      <!--                     style="width: 80px">查看二维码-->
      <!--          </el-button>-->
      <!--          <el-button type="primary" size="mini" @click="handlelock(row)" v-if="row.state===0?false :true"-->
      <!--                     v-show="hasPermission('sys:user:lock')"><span style="margin-left: -0.3rem">锁定用户</span></el-button>-->
      <!--          <el-button type="primary" size="mini" @click="handlelock(row)" v-if="row.state===1?false :true"-->
      <!--                     v-show="hasPermission('sys:user:lock')"><span style="margin-left: -0.3rem">启用</span></el-button>-->
      <!--          <el-button type="primary" size="mini" @click="clearverifier(row)" style="width: 80px"-->
      <!--                     v-show="hasPermission('sys:user:clearverify')">清除验证器-->
      <!--          </el-button>-->
      <!--          <el-button size="mini" type="danger" @click="handleDelete(row)" v-show="hasPermission('sys:user:delete')">删除-->
      <!--          </el-button>-->
      <!--        </template>-->
      <!--      </el-table-column>-->
    </el-table>
    <!-- 底部分页 -->
    <pagination v-show="count > 0" align="center" :total="count" :page.sync="listQuery.page"
                :limit.sync="listQuery.size" @pagination="getList(listQuery.page,listQuery.size)"/>



  </div>
</template>
<script>
  // 后台接口数据
  import {getUserPayCount} from '@/api/user'
  import Pagination from '@/components/Pagination'
  export default {
    name: 'userPayCount',
    components: {Pagination},
    data() {
      return {
        listQuery:{
          page:1,
          size:10
        },
        count:0,
        list:[]
      }
    },

    created() {
      this.getList(1,10)
    },

    methods: {

      getList(page, size) {
        var params = {
          page: page,
          size: size,
        }
        // 得到所有用户的接口
        getUserPayCount(params).then(res => {
          this.list = res.data
          this.count = res.count
          this.listQuery.page=page
          this.listQuery.size=size
        })
          .catch(err => {
          })
      }











    }
  }
</script>
<style>


</style>

